package cn.pfz.statusnum;

import lombok.Getter;

/**
 * @Author: 普发忠
 * @Date: 2021/09/14/10:03
 */
@Getter
public enum ConsumptionStatusEnum {
    CONSUME(0,"待结算"),
    AUDIT(1,"待审核"),
    FINISH(2,"归档"),
    FAILURE(3,"坏账");
    private Integer value;
    private String name;
    ConsumptionStatusEnum(Integer value,String name){
        this.value = value;
        this.name = name;
    }
    public static String getName(Integer value) {
        ConsumptionStatusEnum[] values = values();
        for (ConsumptionStatusEnum appointmentstatusEnum : values) {
            if (appointmentstatusEnum.value.equals(value)) {
                return appointmentstatusEnum.name;
            }
        }
        return null;
    }
}
